//package com.warmguard.core.interceptor;
//
//import com.warmguard.core.core.LoginUserHolder;
//import jakarta.servlet.http.HttpServletRequest;
//import jakarta.servlet.http.HttpServletResponse;
//import org.springframework.lang.Nullable;
//import org.springframework.web.servlet.HandlerInterceptor;
//
///**
// * ClassName: AuthenticationInterceptor
// * PackageName: com.enquan.lease.web.admin.custom.interceptor
// * Description:
// *
// * @Author: 32782
// * @Date: 11/8/2024 下午11:45
// * @Version: 1.0
// */
//public class AuthenticationInterceptor implements HandlerInterceptor {
//    //controller方法调用前
//    @Override
//    public boolean preHandle(HttpServletRequest request, HttpServletResponse response, Object handler) throws Exception {
//        String token = request.getHeader("access-token");
//        JwtUtil.parseToken(token);
//        return true;
//    }
//    //controller方法调用后
//
//    //请求完全处理完毕 才会调用这个方法
//    @Override
//    public  void afterCompletion(HttpServletRequest request, HttpServletResponse response, Object handler, @Nullable Exception ex) throws Exception {
//        // 请求处理完毕 删除
//        LoginUserHolder.removeLoginUser();;
//    }
//}
